<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2022/9/6
  Time: 8:41
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<html>
<head>
    <title>修改电影信息</title>
    <script src="statics/layui.js"></script>
    <link rel="stylesheet" href="statics/css/layui.css"/>
</head>
<style>
    form {
        width: 500px;
        margin: 0px auto;
    }

    form h1 {
        margin-left: 120px;
    }
</style>
<body>
<form action="modify" method="post" class="layui-form-item">
    <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
        <legend>修改电影信息</legend>
    </fieldset>
    <input type="hidden" name="movieId" value="${movie.movieId}">
    <table border="1" class="layui-table">
        <tr>
            <td>电影名称:</td>
            <td><input type="text" name="movieName" value="${movie.movieName}" class="layui-input"></td>
        </tr>
        <tr>
            <td>电影类型:</td>
            <td><input type="text" name="movieType" value="${movie.movieType}" class="layui-input"></td>
        </tr>
        <tr>
            <td>电影价格:</td>
            <td><input type="text" name="price" value="${movie.price}" class="layui-input"></td>
        </tr>
        <tr>
            <td>是否推荐:</td>
            <td>
                <div class="layui-form">
                    <input type="radio" name="recommend" value="1" <c:if test="${movie.recommend==1}">checked</c:if> title="推荐"><div class="layui-unselect layui-form-radio"><i class="layui-anim layui-icon"></i></div>
                    <input type="radio" name="recommend" value="0" <c:if test="${movie.recommend==0}">checked</c:if> title="不推荐"><div class="layui-unselect layui-form-radio layui-form-radioed"><i class="layui-anim layui-icon layui-anim-scaleSpring"></i></div>
                </div>

            </td>
        </tr>
        <tr>
            <td>上映时间:</td>
            <td><input type="text" name="startTime" value="<fmt:formatDate value="${movie.startTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate>" class="layui-input">格式:yyyy-MM-dd</td>
        </tr>
        <tr>
            <td>下映时间:
            <td><input type="text" name="endTime" value="<fmt:formatDate value="${movie.endTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate>" class="layui-input">格式:yyyy-MM-dd</td>
        </tr>
        <tr>
            <td>投票数:</td>
            <td><input type="text" name="votes" value="${movie.votes}" class="layui-input"></td>
        </tr>
        <tr>
            <td>操作:</td>
            <td>
                <input type="submit" value="修改" class="layui-btn layui-btn-normal">
                <input type="button" name="" value="返回" onclick="javascript:history.back()"
                       class="layui-btn layui-btn-primary">
            </td>
        </tr>
    </table>
</form>
</body>
</html>
